import request from '@/utils/request'


// 统计总发送数据
export function countAlarm(type) {
  return request({
    url: '/monitor/sender/countAlarm/' + type,
    method: 'get',
  })
}

// 统计总发送数据
export function countRun() {
  return request({
    url: '/monitor/sender/countRunning',
    method: 'get',
  })
}

// 删除定时任务调度
export function delJob(jobId) {
  return request({
    url: '/monitor/sender/delete/' + jobId,
    method: 'delete'
  })
}
// /listByUUID
// 查询定时任务调度列表
export function listJobByUUID(query) {
  return request({
    url: '/monitor/sender/listByUUID',
    method: 'get',
    params: query
  })
}


// 自动发送
export function autoSendAdd(data) {
  return request({
    url: '/monitor/sender/autoSend/add',
    method: 'post',
    data: data
  })
}
// 批量发送
export function sendBatch(ids,data) {
  return request({
    url: '/monitor/sender/sendBatch/'+ids,
    method: 'post',
    data: data
  })
}
// 单独发送
export function send(data) {
  return request({
    url: '/monitor/sender/send',
    method: 'post',
    data: data
  })
}
// 统计总发送数据
export function count() {
  return request({
    url: '/monitor/sender/countAll',
    method: 'get',
  })
}

// 折线图本月和上月
export function lineChartDefault(type) {
  return request({
    url: '/monitor/sender/count/type/' + type,
    method: 'get'
  })
}

// 折线图自定义
export function lineChart(dates) {
  return request({
    url: '/monitor/sender/count/date/' + dates,
    method: 'post',
  })
}

// // 修改【请填写功能名称】
// export function updatePollutant(data) {
//   return request({
//     url: '/monitor/pollutant',
//     method: 'put',
//     data: data
//   })
// }

// // 删除【请填写功能名称】
// export function delPollutant(id) {
//   return request({
//     url: '/monitor/pollutant/' + id,
//     method: 'delete'
//   })
// }
